<!DOCTYPE HTML>
<html>
    <head>
        <title>EasyBuy后台管理系统</title>
        <meta charset="utf-8">
        <link rel="stylesheet" href="css/login.css">
        <link rel="stylesheet" href="fonts/iconfont.css">
    </head>     
    <body leftmargin="0" onload="changeImg()">
        <div class="main_bar">
            <div id="login_form">
              <p class="title">登录</p>
             <!--   <form action="main.html" onsubmit="return check()">  -->
                <div id="form_widget">
            
                <em class="fu-1  iconfont  icon-zhanghao"></em><span class="num">账&nbsp;&nbsp;&nbsp;号</span>
                <em class="fu-2  iconfont icon-code"></em><span class="yan" >验证码</span>
                 <em class="fu-3  iconfont  icon-mima"></em><span class="pass">密&nbsp;&nbsp;&nbsp;码</span>
                 <div id="j_getVerifyCode" class="getverify-code-btn">发送验证码</div>
              <br>
               <input   type="tel"  id="j_phone" class="phone"  onfocus="this.value=''"/> 
              <br>
               <input type="yan"  id="box_yan" class="txt"  onfocus="this.value=''"/>
              <br>
             <input type="password"  id="box_pass" class="txt"  onfocus="this.value=''"/>
                    <br>             
                    <a href="首页.html">
                      <input  type="submit" value="登录" class="btn"  onclick="this.style.backgroundColor='#EF7632'">
                    </a>
                    <br>
                  <div id="search_pass_link">
                        <a href="#">忘记密码？</a>
                    </div>
                </div>
               <!--  
                      
                 -->
               <!--  </form> -->
            </div>
        </div>
    </body>  
    <script src="js/login.js"></script> 
     <script src="http://www.jq22.com/jquery/jquery-1.10.2.js"></script>
  <script type="text/javascript" src="js/TimerButton.js"></script>
  <script type="text/javascript">
    $(function (){
      console.log(timerButton);

      var btn = $("#j_getVerifyCode");
      timerButton.verify("#j_getVerifyCode", {
        time: 60,//倒计时时间
              event: "click",
              condition: function () {
            var phoneReg = /^(((13[0-9]{1})|(15[0-9]{1})|(18[0-9]{1}))+\d{8})$/,
                  flag = phoneReg.test($("#j_phone").val());

                if(!flag){
                  alert("电话号码填写不正确！");
                  return false;
                }
                return true;
              },
              unableClass: "unabled",//按钮不能使用时的class
              runningText: " s后重新获取",//计时正在进行中时按钮显示的文字
              timeUpText: "重新获取",//时间到了时按钮显示的文字
              progress: function (time) {//计时正在进行中时的回调
                btn.html(time + " s后重新获取");
                console.log(this);//这里的this指向按钮
                console.log(this.timedown);//这个timedown就是计时器
              },
              timeUp: function (time) {//计时结束时执行的回调
                btn.html("重新获取");
                console.log("时间到了！");
                console.log(this);//这里的this指向按钮
              },
              eventFn: function () {//事件执行后的回调
                console.log(this);
                console.log("执行了");
                console.log(this);//这里的this指向按钮
              }
      });
    });
  </script> 
</html>